package br.usp.ime.escola;

import org.nakedobjects.extended.Entity;
import org.nakedobjects.object.AbstractNakedObject;
import org.nakedobjects.object.Title;
import org.nakedobjects.object.collection.ExtendedInternalCollection;
import org.nakedobjects.object.value.TextString;

@Entity
public class Materia extends AbstractNakedObject {

	private static final long serialVersionUID = 1L;

	private final TextString nome = new TextString();

	private final ExtendedInternalCollection matriculas = new ExtendedInternalCollection(
			"Matriculas", Matricula.class, this);

	public TextString getNome() {
		return nome;
	}

	public Title title() {
		return getNome().title();
	}

	public ExtendedInternalCollection getMatriculas() {
		return matriculas;
	}
}
